import {get, post} from "../util/api";


export const login = async <T>(data?: object): Promise<T> => {
    return post("/auth/login", data)
}
export const logout = async <T>(): Promise<T> => {
    return post("/auth/logout")
}

export const verifyEmailCode = async <T>(data?: object): Promise<T> => {
    return post("/email/verifyEmailCode", data)
}


export const register = async <T>(data?: object): Promise<T> => {
    return post("/auth/register", data)
}

export const sendVerificationCode = async <T>(data?: object): Promise<T> => {
    return post("/email/sendLoginOrRegisterEmail" , data)
}
